home *** CD-ROM | disk | FTP | other *** search
/ Games of Daze / Infomagic - Games of Daze (Summer 1995) (Disc 1 of 2).iso / x2ftp / msdos / libs / pdcurs21 / portable / wclear.c < prev    next >
Encoding:
C/C++ Source or Header  |  1993-06-18  |  1.4 KB  |  54 lines

  1. #define    CURSES_LIBRARY    1
  2. #include <curses.h>
  3. #undef    wclear
  4.  
  5. #ifdef PDCDEBUG
  6. char *rcsid_wclear = "$Header: C:\CURSES\portable\RCS\wclear.c 2.1 1993/06/18 20:21:35 MH Rel MH $";
  7. #endif
  8.  
  9.  
  10.  
  11.  
  12. /*man-start*********************************************************************
  13.  
  14.   wclear()    - Clear window
  15.  
  16.   X/Open Description:    clear() and wclear()
  17.      These functions are like erase(), but they also call clearok(),
  18.      arranging that the screen will be cleared completely on the
  19.      next call to wrefresh() for that window and repainted.
  20.  
  21.      NOTE: clear() is a macro.
  22.  
  23.   PDCurses Description:
  24.      There is no additional PDCurses functionality.  This module is
  25.      a documentation place holder.  No code will execute in this module
  26.      unless the user #undefs wclear.
  27.  
  28.   X/Open Return Value:
  29.      The wclear() function returns OK on success and ERR on error.
  30.  
  31.   PDCurses Errors:
  32.      It is an error to call this function with a NULL window pointer.
  33.  
  34.   Portability:
  35.      PDCurses    int wclear( WINDOW* win );
  36.      X/Open Dec '88    int wclear( WINDOW* win );
  37.      BSD Curses    int wclear( WINDOW* win );
  38.      SYS V Curses    int wclear( WINDOW* win );
  39.  
  40. **man-end**********************************************************************/
  41.  
  42. int    wclear( WINDOW *win )
  43. {
  44. #ifdef PDCDEBUG
  45.     if (trace_on) PDC_debug("wclear() - called\n");
  46. #endif
  47.  
  48.     if  (win == (WINDOW *)NULL)
  49.         return( ERR );
  50.  
  51.     clearok( win, TRUE );
  52.     return( werase( win ) );
  53. }
  54.